package com.example.sale.Controller;

import com.example.sale.utils.JwtUtil;
import com.example.sale.utils.MailUtils;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@CrossOrigin
@RequestMapping("mail")
public class MailController {

    @Autowired
    private MailUtils mailUtils;
    @PostMapping("/mail")
    public void sendMail(){
        mailUtils.sendMail("2258131603@qq.com","你好呀","修改密码的验证码");
    }
}
